<template>
  <div id="app">
    <router-view/>
  </div>
</template>
<script>
export default {
  // 防止刷新丢失数据
  created() {
    if (sessionStorage.getItem('store')) {
      this.$store.replaceState(Object.assign({}, this.$store.state, JSON.parse(sessionStorage.getItem('store'))));
    }
    window.addEventListener('beforeunload', () => {
      sessionStorage.setItem('store', JSON.stringify(this.$store.state));
    });
  }
}
</script>
<style>
#app {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  color: #2c3e50;
  font-family: "Helvetica Neue",Helvetica,"PingFang SC","Hiragino Sans GB","Microsoft YaHei","微软雅黑",Arial,sans-serif;
}
* {
  padding:0;
  margin:0;
}

.shotbox {
  width: 1200px;
  height: 100%;
  margin: auto;
  padding: 30px 0;
}
.longbox {
  width: 100%;
  background-color: #F2F6FC;
}
.title {
  font-size: 24px;
  margin-bottom: 20px;
  font-weight: bold;
  text-align: center;
}
.title1 {
  font-size: 14px;
  font-weight: bold;
  text-align: center;
  color: #909399;
  margin-bottom: 30px;
}
.title2 {
  font-size: 24px;
  padding-top: 20px;
  font-weight: bold;
  text-align: center;
}
@media screen and (max-width: 768px) {
  .banner img {
    display: inline-block;
    height: 100%;
    width: 100%;
  }
  .shotbox {
    width: 92%;
  }
  .link-box {
    margin-bottom: 10px;
  }
}
</style>
